#ifndef __ASFTSTATSCREEN_H__
#define __ASFTSTATSCREEN_H__

#include "ASScreen.h"
#include "ASScreenShare.h"
#include "..\control\ASLabel.h"
#include "..\control\ASList.h"
#include "..\control\ASScrollText.h"
#include "..\app\ASAppConst.h"

/*this is related to local setting file.*/
typedef enum
{
    AS_STAT_PAY_MONTHLY,
    AS_STAT_INCOME_MONTHLY,
    AS_STAT_DIFF_MONTHLY,
    AS_STAT_PAY_YEARLY,
    AS_STAT_INCOME_YEARLY,

    AS_STAT_MAX
} as_ftstat_type;

typedef enum
{
    AS_STAT_ST_LIST,//list data
    AS_STAT_ST_HISTOGRAM,//bar graph
    //AS_STAT_ST_PIECHART,//pie graph

    AS_STAT_ST_MAX
} as_ftstat_show_type;

typedef struct
{
    as_screen base;
    as_list* list_p;

} as_ftstat_screen;

void as_ftstat_screen_init(as_screen* screen_p);
void as_ftstat_screen_deinit(as_screen* screen_p);
void as_enter_ftstat_screen(void);

typedef struct
{
    as_screen base;
    as_ftstat_type type;
    as_label* sub_title;
    as_time time;

    as_rect content_area;
    as_ftstat_show_type show_type;
    as_list* list_p;
    as_list* histogram_p;
    ASUINT counts;

    ASUINT64 pay_total_month;
    ASUINT64 income_total_month;
    ASUINT64 pay_months[MONTH_CNTS];
    ASUINT64 income_months[MONTH_CNTS];
    ASUINT64 pay_total_year;
    ASUINT64 income_total_year;

    as_scrolltext* st_p;
} as_ftstatsub_screen;
void as_ftstatsub_screen_init(as_screen* screen_p);
void as_ftstatsub_screen_deinit(as_screen* screen_p);
void as_enter_ftstatsub_screen(void);
void as_ftstatsub_screen_switchto_show_type(as_ftstat_show_type type);
ASUINT as_ftstatsub_screen_get_show_type(void);
#endif //__ASFTSTATSCREEN_H__